import * as React from 'react';
import {IComponentType, IComponentProps} from "../../interfaces";


export default {
  name: 'CARD',
  version: '0.0.1',
  type: IComponentType.DRAG,
  // 嵌套的子组件
  children: [
    { name: 'Grid-Item', type: IComponentType.DRAG, }
  ],

  // 组件配置
  config: {

  },

  // 组件默认
  renderProps: {
    style: { width: 300, height: 100 }
  },

  render ({ Tabs, TabPane, Group, Text, Style, Position, renderProps }: IComponentProps) {
    console.log('---------->', renderProps)
    return (
      <Tabs>
        <TabPane title="属性">
          <Group title="基础配置" show="false">
            <Text field="id" label="id名称" value="id" bind="disable" readonly="true"/>
            <Text field="parent" label="父容器" value="tag" bind="disable" readonly="true"/>
            <Text field="name" label="显示名称" bind="disable" value="按钮" required="true" type="string"/>
          </Group>
          <Group title="布局">
            <Position />
            <Style margin padding border/>
          </Group>
        </TabPane>
      </Tabs>
    )
  },
}